<template>
  <div class="body_all">
    <el-container>
      <el-header>
        <span>
          <img src="./images/logo.jpg" alt="麦嘟云超加盟商管理平台">
        </span>
        <h1>麦嘟云超加盟商管理平台</h1>
      </el-header>
      <el-container>
        <el-aside>
          <el-row>
            <el-menu
              :default-active="$route.path"
              class="el-menu-vertical-demo"
              background-color="#545c64"
              text-color="#fff"
              active-text-color="#409EFF"
              router
            >
              <el-submenu index="/">
                <template slot="title">
                  <span>商品管理</span>
                </template>
                <el-menu-item index="/goodsadmin/inSaleGoods">
                  <i class="el-icon-star-on"></i>在售商品
                </el-menu-item>
                <el-menu-item index="/goodsadmin/goodsAdd">
                  <i class="el-icon-star-on"></i>添加商品
                </el-menu-item>
              </el-submenu>
              <el-submenu index="/purGoods/">
                <template slot="title">
                  <span>采购管理</span>
                </template>
                <el-menu-item index="/purGoods/">
                  <i class="el-icon-star-on"></i>可采购商品
                </el-menu-item>
                <el-menu-item index="2-2">
                  <i class="el-icon-star-on"></i>采购订单
                </el-menu-item>
              </el-submenu>
            </el-menu>
          </el-row>
        </el-aside>
        <el-main>
          <transition name="el-zoom-in-bottom">
            <router-view></router-view>
          </transition>
        </el-main>
      </el-container>
    </el-container>
  </div>
</template>
<script>
export default {
  data() {
    return {};
  },
  methods: {},
  watch: {},
  created() {}
};
</script>
<style scoped lang="scss">
.body_all {
  width: 100%;
  margin: 0 auto;
}
.el-header {
  background-color: #303133;
  color: #fff;
  text-align: left;
  font-family: "Microsoft YaHei", "微软雅黑";
  display: flex;
  align-items: center;
  span {
    display: inline-block;
    img {
      width: 50px;
      height: 50px;
      display: inline-block;
      margin-right: 20px;
    }
  }
  h1 {
    display: inline-block;
    font-size: 18px;
  }
}

.el-aside {
  width: 210px !important;
  background-color: #409eff;
  color: #fff;
  text-align: center;

  .el-row {
    width: 210px !important;
  }
}


.el-main {
  background-color: #e9eef3;
  color: #333;
  text-align: center;
}

/* 左边导航 */
.el-submenu__title {
  span {
    font-size: 20px !important;
    font-weight: bold;
  }
}

.el-menu-item {
  font-size: 14px;
}

// 为什么不起作用呢
.el-menu .el-submenu__title i{
  color: #fff!important;
}
</style>